<?php /* Smarty version 2.6.26, created on 2010-04-27 10:51:04
         compiled from schedule.tpl */ ?>
          <div id = "schedule">
            <div class = "error"><?php echo $this->_tpl_vars['error']; ?>
</div>
            <table cellspacing="0" cellpadding="0" border="0">
              <thead>
                <tr>
                  <th></th>
                  <?php unset($this->_sections['loop']);
$this->_sections['loop']['name'] = 'loop';
$this->_sections['loop']['loop'] = is_array($_loop=$this->_tpl_vars['dates']) ? count($_loop) : max(0, (int)$_loop); unset($_loop);
$this->_sections['loop']['show'] = true;
$this->_sections['loop']['max'] = $this->_sections['loop']['loop'];
$this->_sections['loop']['step'] = 1;
$this->_sections['loop']['start'] = $this->_sections['loop']['step'] > 0 ? 0 : $this->_sections['loop']['loop']-1;
if ($this->_sections['loop']['show']) {
    $this->_sections['loop']['total'] = $this->_sections['loop']['loop'];
    if ($this->_sections['loop']['total'] == 0)
        $this->_sections['loop']['show'] = false;
} else
    $this->_sections['loop']['total'] = 0;
if ($this->_sections['loop']['show']):

            for ($this->_sections['loop']['index'] = $this->_sections['loop']['start'], $this->_sections['loop']['iteration'] = 1;
                 $this->_sections['loop']['iteration'] <= $this->_sections['loop']['total'];
                 $this->_sections['loop']['index'] += $this->_sections['loop']['step'], $this->_sections['loop']['iteration']++):
$this->_sections['loop']['rownum'] = $this->_sections['loop']['iteration'];
$this->_sections['loop']['index_prev'] = $this->_sections['loop']['index'] - $this->_sections['loop']['step'];
$this->_sections['loop']['index_next'] = $this->_sections['loop']['index'] + $this->_sections['loop']['step'];
$this->_sections['loop']['first']      = ($this->_sections['loop']['iteration'] == 1);
$this->_sections['loop']['last']       = ($this->_sections['loop']['iteration'] == $this->_sections['loop']['total']);
?>
                  <?php $_from = $this->_tpl_vars['dates'][$this->_sections['loop']['index']]; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
    foreach ($_from as $this->_tpl_vars['date'] => $this->_tpl_vars['day']):
?>
                  <th><?php echo $this->_tpl_vars['day']; ?>
<br /><span><?php echo $this->_tpl_vars['date']; ?>
</span></th>
                  <?php endforeach; endif; unset($_from); ?>
                  <?php endfor; endif; ?>
                </tr>
              </thead>
				              
              <tbody>
                <?php $_from = $this->_tpl_vars['schedule_rows']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
    foreach ($_from as $this->_tpl_vars['shift'] => $this->_tpl_vars['date']):
?>
                <tr>
                  <th><?php echo $this->_tpl_vars['shift']; ?>
</th>
                  <?php $_from = $this->_tpl_vars['date']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
    foreach ($_from as $this->_tpl_vars['thedate'] => $this->_tpl_vars['people']):
?>
                    <?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "schedule-td.tpl", 'smarty_include_vars' => array()));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>
                  <?php endforeach; endif; unset($_from); ?>
                </tr>
              <?php endforeach; endif; unset($_from); ?>
              </tbody>
            </table>

            <form action="schedule.php" id="change-week" method="POST">
              <input type="button" class="default-button <?php if (! $this->_tpl_vars['prev_id']): ?>hidden<?php endif; ?>" name="back" id="prev_schedule" value="&laquo;" autocomplete="off" />
              <input type="hidden" id="prev_id" value="<?php echo $this->_tpl_vars['prev_id']; ?>
" />
              <input type="button" class="default-button <?php if (! $this->_tpl_vars['next_id']): ?>hidden<?php endif; ?>" name="forward" id="next_schedule" value="&raquo;" autocomplete="off" />
              <input type="hidden" id="next_id" value="<?php echo $this->_tpl_vars['next_id']; ?>
" />
            </form>
            <form action="export-schedule.php" id="export-excel" method="POST">
              <input type="hidden" id="current_id" name = "id" value="<?php echo $this->_tpl_vars['id']; ?>
"/>
              <input type="submit" class = "default-button" name = "submit_1" value = "Download Excel Schedule"/>
            </form>
          </div>